package tech.aistar.day05.exercise;

/**
 * 本类用来演示:
 *
 * @author: success
 * @date: 2022/7/22 2:26 下午
 */
public class Circle extends Shape{
    public final double PI = 3.14;

    private double radius;

    public Circle(double radius) {
        this.radius = radius;
    }

    @Override
    public double area() {
        //Math.PI
        return PI*radius*radius;
    }

    @Override
    public double girth() {
        return 2*PI*radius;
    }
}
